package net.wanho.shop.exception;

import net.wanho.shop.vo.AjaxResult;
import org.springframework.web.bind.annotation.ExceptionHandler;

/**
 * 这个类是：
 *
 * @author: MENG HU WANG
 * @date: 2024/12/27 16:33
 * @version: 1.0
 */
public class CategoryExceptionHandler extends RuntimeException {

    @ExceptionHandler
    public AjaxResult handleException(Exception e) {
        e.printStackTrace();
        return AjaxResult.error(e.getMessage());
    }
}
